<script setup lang="ts">
interface Props {}
const props = withDefaults(defineProps<Props>(), {});
const breadcrumb = ref([
  {
    name: "全部文件",
  },
]);
const emit = defineEmits(["clickName"]);
</script>

<template>
  <div class="breadcrumb">
    <el-breadcrumb separator="/">
      <el-breadcrumb-item
        v-for="(item, index) in breadcrumb"
        :key="index"
        @click="emit('clickName')"
        >{{ item.name }}</el-breadcrumb-item
      >
    </el-breadcrumb>

    <div class="right">
      <el-button
        icon="Refresh"
        @click="emit('clickName', '刷新表格')"
        text
      ></el-button>
    </div>
  </div>
</template>

<style lang="scss" scoped>
.breadcrumb {
  height: px2rem(40px);
  max-height: px2rem(40px);
  display: flex;
  align-items: center;
  .right {
    margin-left: auto;
  }
}
</style>
